package work.xiaohong.websocket.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;
import work.xiaohong.common.eneity.Result;
import work.xiaohong.websocket.vo.UserInfoVo;

import java.math.BigInteger;
import java.util.List;
import java.util.Set;

/**
 * @author xiaohong
 * @version 1.0
 * @date 2021/10/15 0015 10:26
 * @description
 */
@FeignClient(name = "xiaohong-user", contextId = "user")
public interface UserFeign {

    @GetMapping("/user/{userId}")
    Result<UserInfoVo> getById(@PathVariable(value = "userId") BigInteger userId);

    @GetMapping("/user/ids")
    Result<List<UserInfoVo>> getByIds(@RequestParam(value = "ids") List<BigInteger> ids);

}
